﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Windows.Media;
using UBCon.Core.Commands;

namespace UBCon.Ribbon.Models
{
    public class OptionsItemModel:INotifyPropertyChanged
    {
        #region Private fields

        private string imageSource;

        private string title;

        private string description;

        private Command command;

        #endregion

        #region Properies

        /// <summary>
        /// Gets or sets string represantation of image source.
        /// </summary>
        public string ImageSource 
        {
            get 
            {
                return this.imageSource;
            }
            set 
            {
                this.imageSource = value;
                this.OnPropertyChanged("ImageSource");
            } 
        }

        /// <summary>
        /// Gets or sets header text.
        /// </summary>
        public string Title
        {
            get 
            {
                return this.title;
            }
            set 
            {
                this.title = value;
                this.OnPropertyChanged("Title");
            }
        }

        /// <summary>
        /// Gets or sets text of content,
        /// </summary>
        public string Description 
        {
            get 
            {
                return this.description;
            }
            set 
            {
                this.description = value;
                this.OnPropertyChanged("Description");
            }
        }

        public Command Command 
        {
            get 
            {
                return this.command;
            }
            set 
            {
                this.command = value;
                this.OnPropertyChanged("Command");
            } 
        }

        private void OnPropertyChanged(string propertyName) 
        {
            if (this.PropertyChanged != null) 
            {
                this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
            }
        }
        #endregion

        public event PropertyChangedEventHandler PropertyChanged;
    }
}
